#include <iostream>
#include <string>
#include "StdMyString.h"
using namespace std;

int main()
{
#if 0
    StdMyString s = "helloworld";//隐式转换
    // StdMyString s("helloworld");//显示
    std::cout<<s<<std::endl;
    StdMyString s1 = s + ",magi";
    std::cout<<"s1:"<<s1<<std::endl;


    StdMyString s2 = s - "hello" - "ld";
    StdMyString s3("hello");
    StdMyString s4 = s - s3;
    
    std::cout<<"s2:s-hello-ld:"<<s2<<std::endl;
    std::cout<<"s4:s-s3:"<<s4<<std::endl;
#endif

#if 0
    StdMyString s("this");
    StdMyString s2;
    if(s && s2)
    {
        std::cout<<"都不为空"<<std::endl;
    }
    else
    {
        std::cout<<"不都不为空"<<std::endl;
    }
#endif

#if 0
    StdMyString s("zhangsan");
    StdMyString s2("lisi");

    // double num = (double)s;
    std::cout<<(double)s<<std::endl;

    // MyStringList list("zhangsan", "lisi", "nih1po");
    MyStringList list1(s);
    // list1 += s;
    list1 += s2;

    std::cout<<list1;
#endif  

    // StdMyString s("zhangsan, lisi,wangwu");
    // MyStringList list = s.split(",");
    MyStringList list;
    list += "lisi";
    list += "lisi1";
    std::cout<<list<<std::endl;
    return 0;
}